iOS 13 introduced CIFilter "CIKMeans" which is used by the related CIPaletteCentroid and CIPalettize filters.
Are there any examples of the use of CIKMeans? I am mystified by the CIKMeans error "Mean seeds should be passed as a K x 1 image.."
I am using a CIImage as the input for the inputMeans parm.
The inputMeans attribute has this in the parmDictionary
▿ 3 elements
▿ 0 : 2 elements
- key : "CIAttributeDescription"
- value : Specifies the color seeds to use for k-means clustering, either passed as an image or an array of colors.
▿ 1 : 2 elements
- key : "CIAttributeClass"
- value : CIImage
▿ 2 : 2 elements
- key : "CIAttributeDisplayName"
- value : Means"
What is a CIImage that qualifies as a "K x 1" image?
2
0
2.1k